let path="http://localhost:8080/Saxon_Blog_war/"
$(function () {
    $.ajax({
        url: path+"/blog/getBlogNew",
        type: "GET",
        success: function (data) {
            for (let i = 0; i <data.length ; i++) {
                $(".right-recommended-list").append(" <li><a href='calmlog-details.jsp?pid="+data[i].id+"'><i class='fa fa-angle-right' aria-hidden='true'></i>"+ data[i].title+"</a></li>");
            }
        }
    })
    $.ajax({
        url: path+"/blogType/getAllBlogType",
        type: "GET",
        success: function (data) {
            for (let i = 0; i <data.length ; i++) {
                $(".label").append(" <li><a href='calmlog-index.jsp?currentPage=1"+"&Tid="+data[i].id+"'>"+data[i].typeName+'('+data[i].num+')'+"</a></li>");
            }
        }
    })

})

